import React from 'react'
import PropTypes from "prop-types";
//封装标题组件 
function MainTitle(props) {
    return (
        <div className='main-title' style={{
            margin: 0,
            borderLeft: ' 5px solid rgba(0, 0, 0, .7)',
            paddingLeft: 10,
            display: "flex",
            alignItems: 'center'
        }
        }>
            <h1 style={{ fontSize: 32, margin: 0, fontWeight: 'bold' }} > {props.children}</h1>
            {
                !props.render ? '' : props.render
            }
        </div >
    )
}
//类型校验
MainTitle.propTypes = {
    title: PropTypes.object,
}
export default MainTitle